<template>
  <div class="look">
    <div class="top">
      <span style="font-weight: 900; font-size: 22px; color: #000"
        >心脏性猝死</span
      >
      <span style="display: inline-block; margin-left: 10px; color: #000">{{
        info.reportCode
      }}</span>
      <!-- <el-tag
        type="warning"
        style="color: #000; margin-left: 10px"
        size="small"
      >
        <i class="el-icon-info" style="color: orangered"></i>
        该居民已有公卫责任医生【陈丘-中兴村卫生室】负责管档
      </el-tag> -->
      <span style="float: right"
        ><el-button @click="to_bkgl">返回</el-button></span
      >
    </div>
    <el-tabs>
      <el-tab-pane label="报卡信息">
        <p style="font-weight: 700; font-size: 20px">个人信息</p>
        <div class="top">
          <p>
            <span style="font-weight: 900; font-size: 24px; color: #000">{{
              info.residentName
            }}</span>
            <span style="display: inline-block; margin-left: 10px">男</span>
            <span style="display: inline-block; margin-left: 10px">{{
              info.patientBaseInfoDTO.age
            }}</span>
            <el-tag type="warning" size="small" style="margin-left: 15px"
              >已婚</el-tag
            >
            <el-tag type="success" size="small" style="margin-left: 15px"
              >高中</el-tag
            >
            <el-tag type="info" size="small" style="margin-left: 15px"
              >农、林、牧、渔、水利业生产人员</el-tag
            >
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">出生日期：</span>
            <span>{{ info.patientBaseInfoDTO.dataBirth }}</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">证件类别：</span>
            <span>身份证</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">证件号码：</span>
            <span>533221195110170310</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">本人电话：</span>
            <span>15812222586</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">民族：</span>
            <span>{{ info.patientBaseInfoDTO.national | minzu }}</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">工作单位：</span>
            <span>--</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">户籍地址：</span>
            <span
              >云南省丽江市玉龙纳西族自治县黎明傈僳族乡丽江市玉龙县黎明乡中兴村委会柏木组111号</span
            >
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">现住地址：</span>
            <span
              >云南省丽江市玉龙纳西族自治县黎明傈僳族乡丽江市玉龙县黎明乡中兴村委会柏木组111号</span
            >
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">现住地址居住6个月以上：</span>
            <span>是</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">医保类型：</span>
            <span>-</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">联系人姓名：</span>
            <span>和克珍</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">联系人电话：</span>
            <span>15812222586</span>
          </p>
          <p style="display: inline-block; width: 100%">
            <span style="color: #000">备注：</span>
            <span>-</span>
            <span style="display: block; color: blue">编辑</span>
          </p>
          <!--  -->
        </div>
        <p style="font-weight: 700; font-size: 20px; margin-top: 10px">
          患病信息
        </p>
        <div class="top">
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">现住地址居住6个月以上：</span>
            <span>是</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000"> 门诊号：</span>
            <span>-</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">住院号：</span>
            <span>-</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">血糖值（mmol/L）：</span>
            <span>-</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">测量类型：</span>
            <span>-</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">测量日期：</span>
            <span>-</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">诊断类型：</span>
            <span>II型糖尿病</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">并发症：</span>
            <span>否</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">并发性：</span>
            <span>-</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">icd：</span>
            <span>-</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">报告医生：</span>
            <span>史国赟</span>
          </p>
          <p style="display: inline-block; width: 33%">
            <span style="color: #000">报告日期：</span>
            <span>2019-05-30</span>
          </p>
        </div>
      </el-tab-pane>
      <el-tab-pane label="操作记录">
        <el-timeline>
          <el-timeline-item
            v-for="item in list"
            :key="item.id"
            color="rgb(46,160,254)"
            :timestamp="item.created"
            placement="top"
          >
            <el-card>
              <p v-html="item.logContext"></p>
            </el-card>
          </el-timeline-item>
        </el-timeline>
      </el-tab-pane>
    </el-tabs>
  </div>
</template>
  
  <script>
export default {
  data() {
    return {
      info: {
        id: "1995393",
        reportCode: "CC015263230926000001",
        residentName: "丁绍昌",
        mzh: null,
        zyh: null,
        certificateType: 1,
        idCard: "533221194510012712",
        permanentAddress: "云南省丽江市玉龙纳西族自治县黎明傈僳族乡黎明村委会",
        fullPermanentAddress:
          "云南省丽江市玉龙纳西族自治县黎明傈僳族乡黎明村委会云南省丽江市玉龙纳西族自治县黎明傈僳族乡黎明村委会",
        registeredCode: "530721205204",
        nowAddress: "路鲁习组",
        fullNowAddress:
          "云南省丽江市玉龙纳西族自治县黎明傈僳族乡黎明村委会路鲁习组",
        presentCode: "530721205204",
        currentIs: 1,
        healthRecordIs: true,
        remark: null,
        patientBaseInfoDTO: {
          id: "2055328",
          gender: 1,
          age: "78岁",
          national: 48,
          maritalStatus: null,
          telephone: "15969388021",
          education: 8,
          duty: null,
          dataBirth: "1945-10-01",
          workUnit: "无",
          contactName: "丁学仕",
          contactPhone: "15969388021",
          healthType: null,
          residencePlace: null,
          countriesRegions: "CN",
          status: 1,
          isSign: null,
          dutyUserId: "112133",
          residenceArea: null,
          dutyUserName: "吴向成",
          dutyUnitId: "5150",
          dutyUnitName: "黎明村卫生室",
          acuteDuty: null,
          acuteMaritalStatus: 5,
        },
        reportStatus: 2,
        diseaseInfoMap: {
          reportDoctor: "吴向成",
          fate: "0",
          firstDiagnosisDate: "2023-08-27 00:00:00",
          diagnosisDate: "2023-08-27 00:00:00",
          diagnosisSource: "2",
          agencyLevel: "1",
          AcuteMaritalStatus: 5,
          agencyId: "15263",
          icd: "I46.1  被描述为心脏性猝死",
          basis:
            '[{"title":"临床症状","isChe":false},{"title":"肌钙蛋白","isChe":false},{"title":"心电图","isChe":false},{"title":"血管造影","isChe":false},{"title":"超声心动图","isChe":false},{"title":"CT/CTA/SPECT","isChe":false},{"title":"MRI","isChe":false},{"title":"腰穿","isChe":false},{"title":"手术","isChe":false},{"title":"尸检或病理","isChe":false},{"title":"补发","isChe":true}]',
          inferredType: 2,
          agencyName: "黎明乡卫生院",
          reportUnitName: "黎明乡卫生院",
          replacementType: "死亡补发",
          reportDate: "2023-09-02 00:00:00",
          basePatientRelationship: "3",
          reportUnitId: 15263,
          reportDepartment: "黎明村卫生室",
        },
        reportType: 3,
        diseaseType: 9,
        deathInfoMap: null,
        reportUnitId: "15263",
        reportUnitName: "黎明乡卫生院",
        valid: 0,
        fillingUnitId: "15263",
        fillingUnitName: "黎明乡卫生院",
        warningMessage: null,
        residentDeathDate: "2023-08-27",
        isVisit: true,
        visitReportIs: false,
        reportBizStatus: 2,
        dutyUnitId: "5150",
        fullPostalAddress: null,
        acuteDuty: null,
        acuteMaritalStatus: 5,
      },
      list: [
        {
          id: "9766575",
          reportId: "1995393",
          operatorId: null,
          operatorName: "和秀菊",
          unitId: null,
          unitName: "黎明乡卫生院",
          created: "2023-09-26 11:44:13",
          logTemplateId: "21",
          logParamValue:
            '{"unitName":"黎明乡卫生院","assignUnitName":"丽江市疾病预防控制中心，玉龙纳西族自治县疾病预防控制中心","operatorName":"和秀菊"}',
          logContext:
            '和秀菊 <span class="fw" name="unitName">[黎明乡卫生院]</span>分配到<span class="fw" name="assignUnitName">[丽江市疾病预防控制中心，玉龙纳西族自治县疾病预防控制中心]</span>进行审核',
          extraContextQuery: null,
        },
        {
          id: "9766574",
          reportId: "1995393",
          operatorId: null,
          operatorName: "和秀菊",
          unitId: null,
          unitName: "黎明乡卫生院",
          created: "2023-09-26 11:44:13",
          logTemplateId: "1",
          logParamValue:
            '{"unitName":"黎明乡卫生院","operatorName":"和秀菊","action":"保存并提交报卡"}',
          logContext:
            '和秀菊 <span class="fw" name="unitName">[黎明乡卫生院]</span>保存并提交报卡',
          extraContextQuery: null,
        },
      ],
    };
  },
  methods: {
    to_bkgl() {
      this.$router.push("/BKXT/bkgl");
    },
  },
  filters: {
    minzu(val) {
      var mz = "";
      if (val == 1) {
        mz = "汉族";
        return mz;
      }
      if (val == 2) {
        mz = "苗族";
        return mz;
      }
      if (val == 3) {
        mz = "回族";
        return mz;
      }
      if (val == 4) {
        mz = "壮族";
        return mz;
      }
      if (val == 5) {
        mz = "满族";
        return mz;
      }
      if (val == 6) {
        mz = "白族";
        return mz;
      }
      if (val == 7) {
        mz = "蒙古族";
        return mz;
      }
      if (val == 8) {
        mz = "维吾尔族";
        return mz;
      }
      if (val == 9) {
        mz = "土家族";
        return mz;
      }
      if (val == 10) {
        mz = "傣族";
        return mz;
      }
      if (val == 11) {
        mz = "彝族";
        return mz;
      }
      if (val == 12) {
        mz = "藏族";
        return mz;
      }
      if (val == 13) {
        mz = "黎族";
        return mz;
      }
      if (val == 14) {
        mz = "怒族";
        return mz;
      }
      if (val == 15) {
        mz = "景颇族";
        return mz;
      }
      if (val == 16) {
        mz = "朝鲜族";
        return mz;
      }
      if (val == 17) {
        mz = "土族";
        return mz;
      }
      if (val == 18) {
        mz = "门巴族";
        return mz;
      }
      if (val == 19) {
        mz = "水族";
        return mz;
      }
      if (val == 20) {
        mz = "毛南族";
        return mz;
      }
      if (val == 21) {
        mz = "乌孜别克族";
        return mz;
      }
      if (val == 22) {
        mz = "布依族";
        return mz;
      }
      if (val == 23) {
        mz = "布朗族";
        return mz;
      }
      if (val == 24) {
        mz = "东乡族";
        return mz;
      }
      if (val == 25) {
        mz = "仡佬族";
        return mz;
      }
      if (val == 26) {
        mz = "仫佬族";
        return mz;
      }
      if (val == 27) {
        mz = "达斡尔族";
        return mz;
      }
      if (val == 28) {
        mz = "佤族";
        return mz;
      }
      if (val == 29) {
        mz = "羌族";
        return mz;
      }
      if (val == 30) {
        mz = "阿昌族";
        return mz;
      }
      if (val == 31) {
        mz = "纳西族";
        return mz;
      }
      if (val == 32) {
        mz = "拉祜族";
        return mz;
      }
      if (val == 33) {
        mz = "侗族";
        return mz;
      }
      if (val == 34) {
        mz = "京族";
        return mz;
      }
      if (val == 35) {
        mz = "柯尔克孜族";
        return mz;
      }
      if (val == 36) {
        mz = "哈尼族";
        return mz;
      }
      if (val == 37) {
        mz = "哈萨克族";
        return mz;
      }
      if (val == 38) {
        mz = "保安族";
        return mz;
      }
      if (val == 39) {
        mz = "俄罗斯族";
        return mz;
      }
      if (val == 40) {
        mz = "独龙族";
        return mz;
      }
      if (val == 41) {
        mz = "珞巴族";
        return mz;
      }
      if (val == 42) {
        mz = "高山族";
        return mz;
      }
      if (val == 43) {
        mz = "基诺族";
        return mz;
      }
      if (val == 44) {
        mz = "鄂伦春族";
        return mz;
      }
      if (val == 45) {
        mz = "鄂温克族";
        return mz;
      }
      if (val == 46) {
        mz = "塔吉克族";
        return mz;
      }
      if (val == 47) {
        mz = "塔塔尔族";
        return mz;
      }
      if (val == 48) {
        mz = "傈僳族";
        return mz;
      }
      if (val == 49) {
        mz = "畲族";
        return mz;
      }
      if (val == 50) {
        mz = "普米族";
        return mz;
      }
      if (val == 51) {
        mz = "裕固族";
        return mz;
      }
      if (val == 52) {
        mz = "锡伯族";
        return mz;
      }
      if (val == 53) {
        mz = "瑶族";
        return mz;
      }
      if (val == 54) {
        mz = "赫哲族";
        return mz;
      }
      if (val == 55) {
        mz = "撒拉族";
        return mz;
      }
      if (val == 56) {
        mz = "德昂族";
        return mz;
      }
      if (val == 57) {
        mz = "果敢族";
        return mz;
      }
      if (val == 58) {
        mz = "摩梭人";
        return mz;
      }
      if (val == 59) {
        mz = "穿青人族";
        return mz;
      }
      if (val == 60) {
        mz = "其他民族";
        return mz;
      }
    },
  },
};
</script>
  
  <style lang="scss" >
.look {
  padding: 20px;
  background-color: #fff;
  height: calc(100vh - 46px);
  .top {
    padding: 20px;
    border: 1px solid #ccc;
  }
}
::v-deep .el-timeline-item__node--normal {
  left: 0;
}
.fw{
    font-weight: 900;
}
</style>